package com.ruitu.mall_98_2.mvp.model;

import com.ruitu.mall_98_2.dao.APIRetrofit;
import com.ruitu.mall_98_2.mvp.contract.BalanceContract;
import com.ruitu.router_module.bean.api.BaseResult;

import rx.Observable;
import rx.android.schedulers.AndroidSchedulers;
import rx.schedulers.Schedulers;

public class BalanceModel implements BalanceContract.Model {
    @Override
    public Observable<BaseResult<String>> getBalance(String accountId) {
        return APIRetrofit.getDefault().getBalance(accountId)
                .observeOn(AndroidSchedulers.mainThread())
                .subscribeOn(Schedulers.io());
    }

}
